﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="LeadContacts.aspx.cs" Inherits="SD.UI.LeadContacts" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Lead Contacts</title>
    <link type="text/css" rel="Stylesheet" href="CSS/Style.css" />
    <script type="text/javascript">
        function Return()
        {         
            window.close();
        }
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <div>
        <table width="800px">
            <tr>
                <td>
                    <div>
                        <asp:Panel ID="PanelSearchHeader" runat="server">
                            <div>
                                <table width="100%">
                                    <tr>
                                        <td>
                                            <div>
                                                <asp:Label ID="lbFirstName" runat="server" Text="First Name:">
                                                </asp:Label>
                                            </div>
                                        </td>
                                        <td>
                                            <div>
                                                <asp:TextBox ID="tbxFirstName" runat="server">
                                                </asp:TextBox>
                                            </div>
                                        </td>
                                        <td>
                                            <div>
                                                <asp:Label ID="lbSurname" runat="server" Text="Surname:">
                                                </asp:Label>
                                            </div>
                                        </td>
                                        <td>
                                            <div>
                                                <asp:TextBox ID="tbxSurname" runat="server">
                                                </asp:TextBox>
                                            </div>
                                        </td>
                                    </tr>
                                </table>
                            </div>
                        </asp:Panel>
                    </div>
                </td>
            </tr>
            <tr>
                <td style="float:left">
                    <asp:Button ID="btnSearchAddress" runat="server" Text="Search" 
                        onclick="btnSearchAddress_Click" CssClass="Button" />
                    <asp:Button ID="btnNone" runat="server" Text="None" onclick="btnNone_Click" 
                        CssClass="Button" />
                    <asp:Button ID="btnClear" runat="server" Text="Clear" 
                        onclick="btnClear_Click" CssClass="Button" />
                    <asp:Button ID="btnCreate" runat="server" Text="Create" 
                        onclick="btnCreate_Click" CssClass="Button" />
                </td>
            </tr>
            <tr>
                <td>
                    <div>
                    <asp:CheckBox ID="chkInActive" runat="server" Text="Include In-active contact?" 
                            Checked="false" AutoPostBack="True" 
                            oncheckedchanged="chkInActive_CheckedChanged"/>
                    </div>
                </td>
            </tr>
            <tr>
                <td>
                    <div>
                        <asp:Panel ID="PanelFooterSearch" runat="server">
                            <div>
                                <asp:GridView ID="gvSearchAddress" runat="server" AllowPaging="True" 
                                    AutoGenerateColumns="False" BackColor="White" BorderColor="#E7E7FF" 
                                    BorderStyle="None" BorderWidth="1px" CellPadding="3" DataKeyNames="ContactID" 
                                    GridLines="Horizontal" 
                                    onpageindexchanging="gvSearchAddress_PageIndexChanging" Width="100%">
                                    <RowStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" />
                                    <Columns>
                                        <asp:BoundField DataField="ContactID" HeaderText="ID" Visible="False" />
                                        <asp:TemplateField HeaderText="Select">
                                            <ItemTemplate>
                                                <asp:RadioButton ID="rdbChoose" runat="server" AutoPostBack="True" 
                                                    CausesValidation="True" GroupName="selectContact" 
                                                    oncheckedchanged="rdbChoose_CheckedChanged" ValidationGroup="selectContact" />
                                                <!--<input name="rdbChoose" type="radio" value='<%# Eval("ContactType") %>' />-->
                                            </ItemTemplate>
                                        </asp:TemplateField>
                                        <asp:BoundField DataField="ContactName" HeaderText="Contact Name" />
                                        <asp:BoundField DataField="MobilePhone" HeaderText="Mobile Phone" />
                                        <asp:BoundField DataField="Email" HeaderText="Email" />
                                        <asp:BoundField DataField="ContactType" HeaderText="Contact Type" />
                                        <asp:BoundField DataField="IsActive" HeaderText="Is Active?" />
                                    </Columns>
                                    <FooterStyle BackColor="#B5C7DE" ForeColor="#4A3C8C" />
                                    <PagerStyle BackColor="#E7E7FF" ForeColor="#4A3C8C" HorizontalAlign="Right" />
                                    <SelectedRowStyle BackColor="#738A9C" Font-Bold="True" ForeColor="#F7F7F7" />
                                    <HeaderStyle BackColor="#4A3C8C" Font-Bold="True" ForeColor="#F7F7F7" />
                                    <AlternatingRowStyle BackColor="#F7F7F7" />
                                </asp:GridView>
                            </div>
                        </asp:Panel>
                    </div>
                </td>
            </tr>
            <tr>
                <td>
                    <asp:Label ID="lbMessage" runat="server" ForeColor="Red"></asp:Label>
                </td>
            </tr>
            <tr>
                <td style="float:left">
                    <div class="navi">
                        <div>
                        <asp:Button ID="btnSelect" runat="server" Text="Select" 
                            onclick="btnSelect_Click" CssClass="Button" />
                        </div>
                        <div>
                            <asp:Button ID="btnEdit" runat="server" Text="Edit" onclick="btnEdit_Click" 
                            CssClass="Button" />
                        </div>
                            <div onclick="Return()">
                                <asp:Button ID="btnClose" runat="server" Text="Close" 
                                    onclick="btnClose_Click" CssClass="Button" />
                            </div>
                    </div>
                </td>
            </tr>
        </table>
    </div>
    </form>
</body>
</html>
